<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <span id="time"></span>

    <script>
        var time = document.getElementById('time');
    var ks = new Date();
    var msks = ks.getTime();
    var js = msks + 60 * 1 * 1000;
    timeID = setInterval("jsover()", 1000);

    function jsover() {
        var syfz = Math.floor((js - new Date().getTime()) / (1000 * 60)); //计算剩余分钟数 
        var sym = Math.floor((js - new Date().getTime() - syfz * 1000 * 60) / (1000)); //计算剩余的秒数 
        if (syfz < 0) {
            Grade()
        } else
            time.innerHTML = "离考试结束还剩" + syfz + "分" + sym + "秒";
    }

    
    </script>
</body>
</html>